package JavaShengSai;

import java.util.Scanner;

/**
 * 2. 成绩统计
 * https://www.lanqiao.cn/problems/502/learning/?problem_list_id=2&page=1&tag_relation=intersection&tags=2020
 */
public class Main2 {
    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        //在此输入您的代码...
        int n = scan.nextInt();
        int jg = 0;
        int yx = 0;
        for(int i = 0;i < n;i++) {
            int x = scan.nextInt();
            if(x >= 60) {
                if(x >= 85) {
                    yx++;
                }
                jg++;
            }
        }
        // 及格率就是及格的个数 * 100 / n，优秀率也是如此
        System.out.println(Math.round((double)jg * 100 / n) + "%");
        System.out.println(Math.round((double)yx * 100 / n) + "%");

        scan.close();
    }
}
